#!/bin/bash

clear

print_ascii_art() {
    cat << EOF
 ███████╗███████╗██████╗        █████╗ ██╗
 ██╔════╝██╔════╝██╔══██╗      ██╔══██╗██║
 █████╗  ███████╗██████╔╝█████╗███████║██║
 ██╔══╝  ╚════██║██╔═══╝ ╚════╝██╔══██║██║
 ███████╗███████║██║           ██║  ██║██║
 ╚══════╝╚══════╝╚═╝           ╚═╝  ╚═╝╚═╝
EOF
}

print_version() {
    echo -e "\033[32m   当前服务端版本:v2.41.27\033[0m"
    
    echo -e "\033[32m   脚本开源地址:https://gitee.com/zhuxiaohuaqn/ESP-AI-CLI\033[0m"
    
}

print_run_count() {
    response=$(curl -s GET "https://www.qingningz.cn/espapi.php")
    echo -e "\033[32m   脚本已被运行了 $response 次了！快来使用吧！\033[0m"
}

print_info() {
    echo -e "\033[36m------------------------------------------------------------------------------\033[0m"
    echo ""
    echo -e "\033[31m欢迎使用 ESP-AI\033[0m"
    echo -e "\033[31m请使用root用户运行此脚本!\033[0m"
    echo ""
    echo -e "\033[34m官方文档:https://espai.fun\033[0m"
    echo ""
    echo -e "\033[34m本脚本来源于青柠博客:https://www.qingningz.cn\033[0m"
    echo ""
    echo -e "\033[34m如果你想手动安装,请看保姆教程:https://www.qingningz.cn/archives/2231\033[0m"
    echo ""
    echo -e "\033[32m脚本采用 docker 形式安装,不会对当前环境造成影响，请放心使用\033[0m"
    echo ""
    echo -e "\033[32m请确保您已经注册并获取了讯飞开放平台的 appid,apiSecret,apiKey\033[0m"
    echo ""
    echo -e "\033[35m------------------------------------------------------------------------------\033[0m"
}